‫So logout is another important function in applications as a login mechanism log out, you should also
‫be done securely.
‫But sometimes the application doesn't log out the user properly.
‫And of course, this causes some serious privacy problems.
‫There may be hundreds of ways to implement such an insecure logout function.
‫So let's just have a look at one of them from BW.
‫OK, so go to Caleigh and log in to be Web.
‫And from the drop down menu above opened the logout management under broken authentication.
‫OK, so this is a sample authenticated page, and the default level is low.
‫Now view the page source to get some interesting information if, of course, the source has it.
‫And there's nothing here.
‫So when the link is clicked, JavaScript confirmation dialogue will appear and then the location will
‫redirect us to a new page.
‫B.A. underscore logout, underscore one.
‫OK, so now open berp.
‫And activate interception.
‫I'm going to rearrange my brother here for a better view.
‫All right, enabling foxy proxy to send traffic to burb.
‫And now I'm going to click here to logout.
‫OK?
‫And burb capture the lock out request.
‫So let's forward the request.
‫And we get a three oh two redirection response, hmm, so it redirects us to another page with a location
‫header.
‫What is it, log in.
‫So that means that the application log out.
‫Sends us to the login page, doesn't log is out.
‫So this is a general logout mechanism example.
‫And I'm going to forward the next messages as well.
‫And I logged out.
‫So the login page opened in the browser, but do we really log out?
‫OK, so now move on to the back button in the toolbar, right?
‫Click.
‫And you will see pages that we've previously visited and cashed.
‫As you can see, the authenticated page that we visited is right there.
‫So if we go back, the page will be displayed and I forgot the purpose interception mode.
‫So go forward.
‫Disable interception, disable foxe proxy also.
‫And open the page again, as we think it should.
‫So now let's visit some other pages.
‫And as you can see, we're still logged in.
‫So even for the medium and high level, the application really blog out the user.
‫But there are a few differences in the code.
‫So now select medium.
‫And I'm going to click here to log out, OK, so I logged out.
‫But when I pressed the back, but nothing happens.
‫This means that the application did indeed Lagny out.
‫And the same thing happens when I choose the high level.
‫OK, so let's let's go to the code and have a look, see what's happening.
‫Now, I previously downloaded the VoIP application of Cali because sometimes I want to show you the
‫code as well, so I'm going to open the underscore logout, underscore one.
‫And scroll down to see the actual section of logout.
‫I yeah, so it works based on the cookie levels, if the level is low, it does nothing and that's why
‫we can see the page by pressing the back button.
‫And if the level is medium, it just destroys the session.
‫Now, for locking out, it may be enough.
‫But it isn't really secure, is it, because the session related values are still present in the session
‫variable in memory.
‫So this variable also needs to be assigned a null or empty value.
‫And that is done in the high level, as you can see here.
‫So this bug is directly caused by an insecure logout mechanism.
‫But we'll be talking about session problems in the next.
‫I want to go on with a couple of other problems.